Using Arrays

Arrays can be passed to any User Defined Function as a parameter of the function. This means that when you design your function in Visual Basic, the function can accept an array of values of any of the supported data types. However, the function cannot return an array to the Crystal Reports Formula Editor. The following Visual Basic function is an acceptable User Defined Function for Crystal Reports:

Public Function GetNthItem (sArray() As String, n As Integer) As String
    GetNthItem = sArray(n)
End Function


Seagate Software IMG Holdings, Inc.
http://www.seagatesoftware.com
Support services:
http://support.seagatesoftware.com